load("//bazel:tachyon_cc.bzl", "tachyon_cc_library")

package(default_visibility = ["//visibility:public"])

tachyon_cc_library(
    name = "assembly",
    hdrs = ["assembly.h"],
    deps = [
        "//tachyon/base:logging",
        "//tachyon/base:range",
        "//tachyon/math/base:rational_field",
        "//tachyon/zk/plonk/layout:assignment",
        "//tachyon/zk/plonk/permutation:permutation_assembly",
    ],
)

tachyon_cc_library(
    name = "c_proving_key_impl_forward",
    hdrs = ["c_proving_key_impl_forward.h"],
)

tachyon_cc_library(
    name = "key",
    hdrs = ["key.h"],
    deps = [
        ":assembly",
        "//tachyon:export",
        "//tachyon/base/containers:container_util",
        "//tachyon/zk/base/entities:entity",
        "//tachyon/zk/plonk/constraint_system",
    ],
)

tachyon_cc_library(
    name = "proving_key",
    hdrs = ["proving_key.h"],
    deps = [
        ":verifying_key",
        "//tachyon/base:openmp_util",
        "//tachyon/zk/base/entities:prover_base",
        "//tachyon/zk/plonk/halo2:vendor",
        "//tachyon/zk/plonk/permutation:permutation_proving_key",
        "//tachyon/zk/plonk/vanishing:vanishing_argument",
        "//tachyon/zk/plonk/vanishing:vanishing_utils",
    ],
)

tachyon_cc_library(
    name = "proving_key_forward",
    hdrs = ["proving_key_forward.h"],
)

tachyon_cc_library(
    name = "verifying_key",
    hdrs = ["verifying_key.h"],
    deps = [
        ":c_proving_key_impl_forward",
        ":key",
        ":proving_key_forward",
        "//tachyon/base:logging",
        "//tachyon/base/strings:rust_stringifier",
        "//tachyon/zk/plonk/halo2:constants",
        "//tachyon/zk/plonk/halo2:pinned_verifying_key_forward",
        "//tachyon/zk/plonk/halo2:prime_field_conversion",
        "//tachyon/zk/plonk/permutation:permutation_verifying_key",
        "@com_google_boringssl//:crypto",
    ],
)
